package com.cy.pj.sys.service.impl;


import com.cy.pj.sys.dao.DeptDao;
import com.cy.pj.sys.pojo.Dept;
import com.cy.pj.sys.service.DeptService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class DeptServiceImpl implements DeptService {

    @Autowired
    private DeptDao deptDao;

    @Override
    public List<Dept> selectDept() {

        return deptDao.selectDept();

    }

    @Override
    public Dept selectDeptId(Long deptId) {

        return deptDao.selectDeptId(deptId);

    }

    @Override
    public int updateDept(Dept dept) {

        return deptDao.updateDept(dept);

    }

    @Override
    public int insertDept(Dept dept) {

        return deptDao.insertDept(dept);

    }

    @Override
    public int deleteDept(Long id) {

        return deptDao.deleteDept(id);

    }
}
